3.44 \(\int x^2 (a+b \log (c x^n)) \, dx\)

Optimal. Leaf size=27 \[ \frac{1}{3} x^3 \left (a+b \log \left (c x^n\right )\right )-\frac{1}{9} b n x^3 \]

[Out]

-(b*n*x^3)/9 + (x^3*(a + b*Log[c*x^n]))/3

________________________________________________________________________________________

Rubi [A]  time = 0.0121256, antiderivative size = 27, normalized size of antiderivative = 1., number of steps used = 1, number of rules used = 1, integrand size = 14, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.071, Rules used = {2304} \[ \frac{1}{3} x^3 \left (a+b \log \left (c x^n\right )\right )-\frac{1}{9} b n x^3 \]

Antiderivative was successfully verified.

[In]

Int[x^2*(a + b*Log[c*x^n]),x]

[Out]

-(b*n*x^3)/9 + (x^3*(a + b*Log[c*x^n]))/3

Rule 2304

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))*((d_.)*(x_))^(m_.), x_Symbol] :> Simp[((d*x)^(m + 1)*(a + b*Log[c*x^
n]))/(d*(m + 1)), x] - Simp[(b*n*(d*x)^(m + 1))/(d*(m + 1)^2), x] /; FreeQ[{a, b, c, d, m, n}, x] && NeQ[m, -1
]

Rubi steps

\begin{align*} \int x^2 \left (a+b \log \left (c x^n\right )\right ) \, dx &=-\frac{1}{9} b n x^3+\frac{1}{3} x^3 \left (a+b \log \left (c x^n\right )\right )\\ \end{align*}

Mathematica [A]  time = 0.001165, size = 32, normalized size = 1.19 \[ \frac{a x^3}{3}+\frac{1}{3} b x^3 \log \left (c x^n\right )-\frac{1}{9} b n x^3 \]

Antiderivative was successfully verified.

[In]

Integrate[x^2*(a + b*Log[c*x^n]),x]

[Out]

(a*x^3)/3 - (b*n*x^3)/9 + (b*x^3*Log[c*x^n])/3

________________________________________________________________________________________

Maple [C]  time = 0.167, size = 112, normalized size = 4.2 \begin{align*}{\frac{b{x}^{3}\ln \left ({x}^{n} \right ) }{3}}+{\frac{{x}^{3} \left ( 3\,ib\pi \,{\it csgn} \left ( i{x}^{n} \right ) \left ({\it csgn} \left ( ic{x}^{n} \right ) \right ) ^{2}-3\,ib\pi \,{\it csgn} \left ( i{x}^{n} \right ){\it csgn} \left ( ic{x}^{n} \right ){\it csgn} \left ( ic \right ) -3\,ib\pi \, \left ({\it csgn} \left ( ic{x}^{n} \right ) \right ) ^{3}+3\,ib\pi \, \left ({\it csgn} \left ( ic{x}^{n} \right ) \right ) ^{2}{\it csgn} \left ( ic \right ) +6\,b\ln \left ( c \right ) -2\,bn+6\,a \right ) }{18}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(x^2*(a+b*ln(c*x^n)),x)

[Out]

1/3*b*x^3*ln(x^n)+1/18*x^3*(3*I*b*Pi*csgn(I*x^n)*csgn(I*c*x^n)^2-3*I*b*Pi*csgn(I*x^n)*csgn(I*c*x^n)*csgn(I*c)-
3*I*b*Pi*csgn(I*c*x^n)^3+3*I*b*Pi*csgn(I*c*x^n)^2*csgn(I*c)+6*b*ln(c)-2*b*n+6*a)

________________________________________________________________________________________

Maxima [A]  time = 1.02609, size = 35, normalized size = 1.3 \begin{align*} -\frac{1}{9} \, b n x^{3} + \frac{1}{3} \, b x^{3} \log \left (c x^{n}\right ) + \frac{1}{3} \, a x^{3} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x^2*(a+b*log(c*x^n)),x, algorithm="maxima")

[Out]

-1/9*b*n*x^3 + 1/3*b*x^3*log(c*x^n) + 1/3*a*x^3

________________________________________________________________________________________

Fricas [A]  time = 0.862332, size = 82, normalized size = 3.04 \begin{align*} \frac{1}{3} \, b n x^{3} \log \left (x\right ) + \frac{1}{3} \, b x^{3} \log \left (c\right ) - \frac{1}{9} \,{\left (b n - 3 \, a\right )} x^{3} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x^2*(a+b*log(c*x^n)),x, algorithm="fricas")

[Out]

1/3*b*n*x^3*log(x) + 1/3*b*x^3*log(c) - 1/9*(b*n - 3*a)*x^3

________________________________________________________________________________________

Sympy [A]  time = 0.818564, size = 36, normalized size = 1.33 \begin{align*} \frac{a x^{3}}{3} + \frac{b n x^{3} \log{\left (x \right )}}{3} - \frac{b n x^{3}}{9} + \frac{b x^{3} \log{\left (c \right )}}{3} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x**2*(a+b*ln(c*x**n)),x)

[Out]

a*x**3/3 + b*n*x**3*log(x)/3 - b*n*x**3/9 + b*x**3*log(c)/3

________________________________________________________________________________________

Giac [A]  time = 1.09674, size = 42, normalized size = 1.56 \begin{align*} \frac{1}{3} \, b n x^{3} \log \left (x\right ) - \frac{1}{9} \, b n x^{3} + \frac{1}{3} \, b x^{3} \log \left (c\right ) + \frac{1}{3} \, a x^{3} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x^2*(a+b*log(c*x^n)),x, algorithm="giac")

[Out]

1/3*b*n*x^3*log(x) - 1/9*b*n*x^3 + 1/3*b*x^3*log(c) + 1/3*a*x^3